<?php
	if ($month == 1) {
		$temp_month = 12;
		$temp_year = $year - 1;
	}
	else {
		$temp_month = $month - 1;
		$temp_year = $year;
	}
	$prev_month_offset = cal_days_in_month(0, $temp_month, $year);
?>

<a href="viewMonth.php?month=<?php echo $temp_month ?>&year=<?php echo $temp_year ?>">&lt;</a> 

<?php echo "<span class='dateheader'>$month_name $year</span>"; ?>

<?php
	if ($month == 12) {
		$temp_month = 1;
		$temp_year = $year + 1;
	}
	else {
		$temp_month = $month + 1;
		$temp_year = $year;
	}
?>

<a href="viewMonth.php?month=<?php echo $temp_month ?>&year=<?php echo $temp_year ?>">&gt;</a> 
